import Mock from 'mockjs';


export default {
  //
    className: "product.model.OnTimeOrder",
    queryData: function(postData) {
        return Mock.mock({
            isSuccess: "Y",
            reason: "",
            message: [],
            "data": {
                "recordCount": 38,
                "pageCount": 1,
                "pageIndex": 1,
                "pageSize": 20,
                "queryResult|38": [{
                    "keyID|1000-9999": 1000,
                    "orderCode": /^[0-9][0-9][0-9][0-9][0-9][0-9]$/,
                    "userAccount": /^[A-Z][a-z][a-z][a-z][a-z][A-Z][a-z][a-z][a-z][a-z]$/,
                    "productCode": /^[0-9][0-9][0-9][0-9][0-9][0-9]$/,
                    "productName": Mock.mock('@ctitle'),
                    "orderTime": Mock.mock('@now'),
                    "effectiveTime": Mock.mock('@now'),
                    "status": "已完成",
                    "invalidTime": Mock.mock('@now'),
                    "paymentStatus": "已支付",
                    "automaticRenew": "是",
                    "version": 1,

                }]
            }
        });
    },
    queryByKeyID: function(postData) {
        return Mock.mock({
            isSuccess: "Y",
            reason: "",
            message: [],
            "data": {
              "keyID|1000-9999": 1000,
                    "orderCode": Mock.mock('@ctitle'),
                    "userAccount":Mock.mock('@ctitle'),
                    "productCode": /^[a-z][a-z][a-z][a-z][a-z]$/,
                    "productName": Mock.mock('@ctitle'),
                    "orderTime": Mock.mock('@now'),
                    "effectiveTime": Mock.mock('@now'),
                    "status": "admin",
                    "invalidTime": "admin",
                    "paymentStatus": "admin",
                    "automaticRenew": "admin",
                    "version": 1,
            }
        });
    },
};
